home *** CD-ROM | disk | FTP | other *** search
/ Night Owl 6 / Night Owl's Shareware - PDSI-006 - Night Owl Corp (1990).iso / 015a / pko10j.zip / PKO.DOC next >
Text File  |  1991-08-11  |  19KB  |  479 lines

  1.  
  2.    Palindrome KickOff! manual
  3.    (C) Copyright Darryl G. Whitmore 1990, 1991.  All Rights Reserved.
  4.  
  5.  
  6.     1.00 Introduction
  7.  
  8.    Hello!  I'm Darryl G. Whitmore, and I work as a programmer for the
  9.    Palindrome Corporation, maker of The Network Archivist (TNA).  During
  10.    my free time, I like to work on software utilities, and Palindrome
  11.    KickOff! (PKO) is one of my little projects.
  12.  
  13.    PKO is a utility designed for doing secure, unattended backup
  14.    (preferrably using TNA!).  Credit for the idea goes to TNA user Joe
  15.    Swenn.  He was concerned about doing unattended overnight backup
  16.    because the workstation running TNA must be left logged in with with
  17.    supervisor equivalence (this was in the TNA 1.x days; TNA 2.0 has a
  18.    secure Auto-Login feature). He wrote a program (in ZBASIC, I think)
  19.    that would execute TNA at the desired time.  You couldn't "get out"
  20.    of this program (and thus have access to the workstation and the LAN)
  21.    unless you knew the right password.  The only other way to stop the
  22.    program was to reboot the workstation, and in doing so, the
  23.    supervisor equivalence is lost.  I thought that this was a great
  24.    idea, and decided to see if I could write such a program.  PKO is
  25.    what I came up with!
  26.  
  27.     2.00 Installation & Upgrading
  28.  
  29.    The PKO package is distributed in a ZIP file (PKOnnn.ZIP, where nnn =
  30.    the version).  The package consists of:
  31.  
  32.       PKO.EXE        PKO itself
  33.       PKO.DOC        PKO's manual
  34.       VERSION.DOC    PKO's version history ("what's new")
  35.       REGISTER.DOC   PKO's registration form
  36.  
  37.    To install PKO, simply copy PKO.EXE and its associated documentation
  38.    files (*.DOC) into any directory present in your PATH (any directory
  39.    that has a search mapping "pointing" to it).  I suggest putting PKO
  40.    in the directory where TNA's executables (.EXE files) are located
  41.    (usually \TNA).
  42.  
  43.    If you're upgrading from an earlier version of PKO, the upgrade
  44.    process is the same: simply copy the new PKO files into the directory
  45.    where your existing version of PKO resides.  Your existing PKO
  46.    configuration and log files will be safe; the format of these files
  47.    has not changed. 
  48.  
  49.     3.00 Syntax
  50.  
  51.    PKO will display its syntax if you simply execute:
  52.  
  53.       PKO
  54.  
  55.    It will also display the syntax if invalid command line arguments are
  56.    entered.  Here is the syntax:
  57.  
  58.       PKO mode
  59.  
  60.       modes:
  61.  
  62.        /M             Run PKO in Menu Mode
  63.        /W [switches]  Run PKO in Wait Mode
  64.  
  65.        switches:
  66.          /OThh:mm     Override kickoff time
  67.          /OCcommand   Override kickoff command
  68.  
  69.     4.00 Quick start
  70.  
  71.    To get going with PKO ASAP, here is a quick start.  Once you have PKO
  72.    working and have the general idea, you can refer back to the more detailed
  73.    tutorial that follows.
  74.  
  75.    First, install PKO as detailed above (in 2.00).  Next, enter the following
  76.    command:
  77.  
  78.       PKO /M
  79.  
  80.    PKO will ask you for a password, and once you've given it one, select
  81.    "Change KickOff options..." from the main menu.  Proceed to enter a
  82.    kickoff command and time.  For your quick start kickoff command, you might
  83.    choose something like: "TNA2TAPE /A /Q".  For the kickoff time, enter the
  84.    time that it will be in about 5 minutes (use 24 hour format).  After
  85.    you've configured PKO for kickoff, press ESC from the main menu to return
  86.    to DOS.
  87.  
  88.    Now that you've configured PKO, execute the following command to start it
  89.    up:
  90.  
  91.       PKO /W
  92.  
  93.    PKO will now wait around until kickoff time, which should be in about 5
  94.    minutes.  During this time, you won't be able to "break" out of PKO,
  95.    either with CTRL-C or CTRL-BREAK.  The only way to stop PKO is to press
  96.    ESC and when prompted, provide your password.
  97.  
  98.    Watch PKO tick off the time, and then, at kickoff time, it will execute
  99.    the kickoff command.
  100.  
  101.     5.00 Tutorial
  102.  
  103.    One more time, then, here is a detailed tutorial on how to setup and use
  104.    PKO.
  105.  
  106.     5.10 Configuration
  107.  
  108.    PKO needs to know what command you want to execute, what time you
  109.    want to execute it, and what your password will be.  To configure PKO
  110.    with this information, run PKO in "Menu Mode" by entering the
  111.    following command at the DOS prompt:
  112.  
  113.       PKO /M
  114.  
  115.    PKO will first ask you to enter and verify your password.  You
  116.    have 20 characters for your password, and can use just about any word
  117.    or sentence.  Don't forget your password!
  118.  
  119.    Once past the password barrier, select "Change KickOff options..."
  120.    from the main menu to enter your configuration:
  121.  
  122.  
  123.    The "Command" is the command that you want PKO to execute.  It
  124.    can be any valid DOS command, a program or a batch file.
  125.  
  126.    The "Time" is the time that you want PKO to execute your command. 
  127.    You enter the time in 24 hour format: 22:30 is equal to 10:30pm.  The
  128.    exception is midnight, which is entered as 00:00 (just as it is with
  129.    the DOS TIME command).
  130.  
  131.    Once you have configured PKO, select "Exit to DOS" from the main
  132.    menu to return to DOS.  If you take a look in the directory where
  133.    you've installed PKO, you'll find a new file: PKO.CFG.  This is where
  134.    PKO keeps your configuration information.  For security, it is
  135.    encrypted.
  136.  
  137.     5.20 Running PKO
  138.  
  139.    To have PKO "kickoff" your command, run it in "Wait Mode" by
  140.    entering the following command at the DOS prompt:
  141.  
  142.       PKO /W
  143.  
  144.    You'll see PKO's Wait Mode status box, which displays the current
  145.    date and time, as well as the kickoff command and time, and a
  146.    countdown to the kickoff.  Each minute, the status box will change
  147.    positions, or bounce (I call it the "bouncing box").  This is so that
  148.    the status box doesn't burn its image into your monitor.  This
  149.    bouncing is random and will occur every minute; I kind of like to
  150.    just sit and watch it (but then, I spend my free time writing little
  151.    utilities like this).
  152.  
  153.    To suspend Wait Mode and return to DOS, press ESC at any time. 
  154.    PKO will then give you 10 seconds to input your password.  If you
  155.    take longer than 10 seconds, or input an incorrect password, wait
  156.    mode will resume.
  157.  
  158.    When kickoff time arrives, PKO will "stuff" your command into the
  159.    keyboard buffer (along with a carriage return) and return to DOS. 
  160.    DOS will then look for the next sequence of keystrokes in the buffer,
  161.    and process them.  The effect is the same as if you had waited at your
  162.    machine until kickoff time and then typed in the command yourself. It's
  163.    important to note that PKO, unlike a terminate & stay resident (TSR)
  164.    program, doesn't remain in memory when it runs your command; your
  165.    command has the benefit of having access to all available free RAM.
  166.  
  167.     5.30 Additional security
  168.     
  169.    PKO does a good job of kicking off your command at the appointed time
  170.    and keeping the workstation secure during Wait Mode, but you'll need
  171.    to do a little more work to have a truly seamless, secure unattended
  172.    backup.  To do this, you'll typically configure PKO to execute a
  173.    batch file.  For example, let's call the batch file BACKUP.BAT. 
  174.    Here's what it looks like:
  175.  
  176.       TNA2TAPE /A /Q
  177.       PKO /W
  178.  
  179.    PKO kicks off BACKUP.BAT, which runs a TNA automatic archive in
  180.    quiet mode.  When this is done, the batch file re-runs PKO in Wait
  181.  
  182.    Mode.  This method insures that the workstation is secure after the
  183.    backup, as well as before.  This version of BACKUP.BAT accomplishes
  184.    the same thing:
  185.  
  186.       TNA2TAPE /A /Q
  187.       LOGOUT
  188.  
  189.    One final note: you'll need to make sure that no one can tamper with
  190.    BACKUP.BAT; it wouldn't be difficult to compromise your security by
  191.    modifying the batch file that PKO executes!  I'd suggest putting it
  192.    in a subdirectory that is only "visible" to the supervisor.
  193.  
  194.     5.40 The PKO log file.
  195.  
  196.    PKO maintains a log when it is in Wait Mode.  The log file is called
  197.    PKO.LOG, and will be found in the directory where you've installed
  198.    PKO.  It is a simple ASCII file, and may be viewed with any word
  199.    processor or editor.  PKO makes log entries when "interesting" events
  200.    occur, such as:
  201.  
  202.       - When Wait Mode begins, ends, and is suspended
  203.       - When invalid passwords are entered during Wait Mode
  204.       - When errors occur
  205.       - On the hour & half hour
  206.  
  207.    You'll probably want to review PKO's log regularly.  It is generally
  208.    quite boring, but may some day alert you to the fact that an intruder
  209.    tried to suspend Wait Mode by trying several bad passwords.
  210.  
  211.    Over time, the log file will grow in size.  You may delete it (or edit
  212.    it to remove old entries) at any time.
  213.  
  214.     5.50 Running PKO with command line overrides.
  215.  
  216.    For added flexibility, you may override PKO's configured kickoff time
  217.    and command.  This is done via optional command line switches that
  218.    are used in conjunction with the Wait Mode command line switch (/W). 
  219.    Both command line overrides may be used together.
  220.  
  221.     5.51 Overriding the kickoff time
  222.  
  223.    The configured kickoff time may be overridden with the /OT switch. 
  224.    This switch requires a parameter: the override time itself.  For
  225.    example, if you wanted to override the configured kickoff time and have
  226.    PKO kickoff at 8:45am, the command line would be:
  227.  
  228.       PKO /W /OT08:45
  229.  
  230.    Note that the override kickoff time parameter must come right after
  231.    the switch; no spaces or colons (:) or equals signs (=) are allowed.
  232.    Note also that the override kickoff time parameter must be in hh:mm
  233.    format (ie, pad the hour with a leading "0" if necessary).  The
  234.    override kickoff time must be in 24 hour format (see 5.10 above).
  235.  
  236.    A powerful feature of the override time switch is the ability to use "Hour
  237.    Wildcards".  The Hour Wildcards are question marks that are used in place
  238.    of the hour part of the override kickoff time.  When the wildcards are
  239.    used, they instruct PKO to "substitute with the next hour".  For example,
  240.    let's say that you execute the following command line at 3:30pm:
  241.  
  242.  
  243.       PKO /W /OT??:15
  244.  
  245.    PKO will begin Wait Mode with kickoff scheduled for 4:15pm.  Using an
  246.    override kickoff time and Hour Wildcards, you can configure PKO to
  247.    back up your system all day long, at the top of the hour. First,
  248.    change BACKUP.BAT to read:
  249.  
  250.       TNA2TAPE /A /Q
  251.       PKO /W /OT??:00
  252.  
  253.    Next, initiate Wait Mode with:
  254.  
  255.       PKO /W /OT??:00
  256.  
  257.    PKO will start the backup at the top of each hour, until you suspend
  258.    Wait Mode.
  259.  
  260.     5.52 Overriding the kickoff command
  261.  
  262.    The configured kickoff command may be overridden with the /OC switch.
  263.    This switch requires a parameter: the override command itself.  For
  264.    example, if you wanted to override the configured kickoff command
  265.    with TNA2TAPE /A /Q, the command line would be:
  266.  
  267.       PKO /W /OC"TNA2TAPE /A /Q"
  268.  
  269.    Note that because the kickoff command contains embedded spaces, it
  270.    must be enclosed in double quotes (").  The command must also be
  271.    enclosed in double quotes if it contains forward slashes (/); this is
  272.    necessary because otherwise, PKO would mistake the slashes for its
  273.    own command line switches.  Our example above happens to contain both
  274.    embedded spaces and forward slashes.  Here are some other examples:
  275.  
  276.       PKO /W /OCDO_BACKUP        (no need for quotes)
  277.       PKO /W /OC"DO_BACKUP F:"   (embedded spaces, need quotes)
  278.       PKO /W /OC"TNA2TAPE/A"     (no embedded spaces, but forward slash)
  279.  
  280.    Finally, note that the override kickoff command, like the kickoff command
  281.    that is configured in Menu Mode, is limited to 14 characters.
  282.  
  283.     5.60 Running PKO with the Weekday Macro.
  284.  
  285.    The Weekday Macro allows you increased flexibility when you use PKO
  286.    to kickoff a batch file.  The Weekday Macro is the percent sign (%),
  287.    and to use it all you have to do is embed it somewhere in your
  288.    kickoff command.  When PKO kicks off, it will "expand" the macro
  289.    according to the current day:
  290.  
  291.       Sunday    = 1 
  292.       Monday    = 2 
  293.       Tuesday   = 3 
  294.       Wednesday = 4 
  295.       Thursday  = 5 
  296.       Friday    = 6 
  297.       Saturday  = 7
  298.  
  299.    There are a couple ways to use the Weekday Macro with batch files. 
  300.    First, you can use it to provide a parameter to your batch file.  For
  301.  
  302.    example, let's say you configure your kickoff command to be:
  303.  
  304.       BACKUP %
  305.  
  306.    Your batch file, BACKUP.BAT, would receive the current day via
  307.    parameter 1 (which is referenced as %1 within the batch file), and
  308.    would need to evaluate it, something like this:
  309.  
  310.    REM
  311.    REM   Evaluate day & branch accordingly.
  312.    REM
  313.          IF "%1" == "1" goto SUN
  314.          IF "%1" == "2" goto MON
  315.          IF "%1" == "3" goto TUE
  316.          IF "%1" == "4" goto WED
  317.          IF "%1" == "5" goto THU
  318.          IF "%1" == "6" goto FRI
  319.          IF "%1" == "7" goto SAT
  320.    :SAT
  321.    :SUN
  322.    REM
  323.    REM   Don't run on the weekends.
  324.    REM
  325.          GOTO DONE
  326.    :MON
  327.    :TUE
  328.    :WED
  329.    :THU
  330.    REM
  331.    REM   Do automatic archiving during the week.
  332.    REM
  333.          TNA2TAPE /A /Q
  334.          GOTO DONE
  335.    :FRI
  336.    REM
  337.    REM   Do a full checkpoint on Friday
  338.    REM
  339.          TNA2TAPE /FC /Q
  340.          GOTO DONE
  341.    :DONE
  342.          PKO/W
  343.  
  344.    This example doesn't have much basis in reality, but it should give
  345.    you an idea how you can use the Weekday Macro as a parameter.
  346.  
  347.    A second way to use the Weekday Macro is by having a different batch
  348.    file for each day of the week.  With this method, the macro is not a
  349.    parameter, but a part of the batch file's name.  For example, let's
  350.    say you configure your kickoff command to be:
  351.  
  352.       BACKUP%
  353.  
  354.    Then, you'd have 7 separate batch files, named BACKUP1.BAT,
  355.    BACKUP2.BAT, BACKUP3.BAT, etc.  In keeping with the above example,
  356.    here's what the batch files might look like:
  357.  
  358.    BACKUP1.BAT & BACKUP7.BAT
  359.    -------------------------
  360.    REM
  361.  
  362.    REM   Don't run on the weekends.
  363.    REM
  364.          PKO/W
  365.  
  366.    BACKUP2.BAT through BACKUP5.BAT
  367.    -------------------------------
  368.    REM
  369.    REM   Do automatic archiving during the week.
  370.    REM
  371.          TNA2TAPE /A /Q
  372.          PKO/W
  373.  
  374.    BACKUP6.BAT
  375.    -----------
  376.    REM
  377.    REM   Do a full checkpoint on Friday
  378.    REM
  379.          TNA2TAPE /FC /Q
  380.          PKO/W
  381.  
  382.    Note that when using this method, PKO will issue a warning when
  383.    beginning Wait Mode because it won't be able to verify the existence
  384.    of the kickoff command.  That is, because of the Weekday Macro, the
  385.    exact kickoff command can't be known until kickoff time, so PKO won't
  386.    be able to find it when it does its initial check at the beginning of
  387.    Wait Mode.  You can disregard this warning.
  388.  
  389.    You can choose to use either method.  I myself prefer the first, as
  390.    it keeps all the commands in one place, which makes for easier
  391.    maintenance.  It also provides better readability. Apart from that,
  392.    either method will function just fine; it's just a matter of your own
  393.    preference.
  394.  
  395.     6.00 Notes
  396.  
  397.    As previously mentioned, PKO operates by "stuffing" your command into
  398.    the computer's keyboard buffer.  PKO expects the keyboard buffer to
  399.    be in the standard location: 0040:001Eh.  This should be true unless
  400.    you are using a keyboard buffer device driver to expand the buffer
  401.    size (the default size is 15 bytes, and device drivers are available
  402.    to expand this size).  If so, you'll need to test PKO thoroughly and
  403.    if necessary, remove the device driver.  I speak from experience!  I
  404.    was using such a device driver, and PKO seemed to work just fine. 
  405.    Then, from the DOS prompt, I pressed a key and my monitor displayed a
  406.    kaleidoscope of colors!
  407.  
  408.    If you happen to forget your password, don't despair.  Simply delete
  409.    PKO.CFG.  You'll then have to reconfigure PKO as in 5.10, above.  At
  410.    this point in PKO's development, this is not a problem, as the
  411.    configuration file contains only a few items of data.
  412.  
  413.     7.00 Registration
  414.  
  415.    PKO is Shareware.  What is Shareware?  Shareware is simply an
  416.    alternate method of marketing and distribution.  With Shareware, you
  417.    get to "test drive" a program before you buy.  If you continue to use
  418.    a Shareware program after a reasonable amount of time (say, a couple
  419.    or weeks or so for PKO), you're expected to register it.
  420.  
  421.  
  422.    The registration fee for PKO is $15.00.  To register, fill out the
  423.    registration form (see the file, REGISTER.DOC) and mail it to me
  424.    along with your payment of $15.00.  Upon receipt of your
  425.    registration, I will send you the current version of PKO, unless you
  426.    already have the current version.  In that case, I will still
  427.    acknowledge your registration, and send you the next version when it
  428.    is available.
  429.  
  430.     8.00 Distribution
  431.     
  432.    You are encouraged to distribute PKO in any manner; this is a basic
  433.    principle of Shareware.  You may not charge a fee for your
  434.    distribution; however, a nominal duplication or shipping and
  435.    handling fee of no more than $3.00 is allowed.
  436.  
  437.    You must distribute the entire PKO package.  That is, all files
  438.    included in the ZIP file as specified in 2.00 above. 
  439.  
  440.     9.00 Support
  441.  
  442.    The best way to reach me is via CompuServe Mail.  My account is
  443.    71760,2565.  Alternately, you may drop me a line:
  444.  
  445.         Darryl G. Whitmore
  446.         48 West Fern Court
  447.         Palatine, IL  60067-1402
  448.  
  449.    You may also contact me for support and help during the "test drive"
  450.    phase.
  451.  
  452.    PKO has had over a year of use in "the field" without any reported
  453.    hardware or software incompatibilties.  If you register PKO and
  454.    subsequently encounter compatibility problems (or others, for that
  455.    matter) that I can't resolve, I'll gladly refund of your
  456.    registration.
  457.  
  458.    10.00 The "to do" list
  459.  
  460.    I have in mind a number of enhancements to PKO, among them:
  461.  
  462.       - A facility for viewing PKO.LOG from within Menu Mode.
  463.       - Automatic purging of PKO.LOG when it reaches a certain size
  464.         or age.
  465.       - Enhanced kickoff configuration, such as:
  466.          - different commands for different days of the week
  467.          - kickoff after a certain length of time, rather than
  468.            only at a certain time
  469.          - configurable parameters that may be passed to the
  470.            kickoff command
  471.       - A command line override to make PKO kickoff _after_ a certain
  472.         length of time.  For example, /OA04:00 to kickoff 4 hours
  473.         after Wait Mode is initiated.
  474.     
  475.    Past PKO enhancements have been based on users' feature requests, and
  476.    no doubt future enhancements will be, also. I welcome suggestions or
  477.    comments.  Please feel free to contact me as outlined in 9.00, above. 
  478.  
  479.